<include file="public@header"/>
<style type="text/css">
    .pic-list li {
        margin-bottom: 5px;
    }
</style>
<script type="text/html" id="photos-item-tpl">
    <li id="saved-image{id}">
        <input id="photo-{id}" type="hidden" name="photo_urls[]" value="{filepath}">
        <input class="form-control" id="photo-{id}-name" type="text" name="photo_names[]" value="{name}"
               style="width: 200px;" title="图片名称">
        <img id="photo-{id}-preview" src="{url}" style="height:36px;width: 36px;"
             onclick="imagePreviewDialog(this.src);">
        <a href="javascript:uploadOneImage('图片上传','#photo-{id}');">替换</a>
        <a href="javascript:(function(){$('#saved-image{id}').remove();})();">移除</a>
    </li>
</script>
<script type="text/html" id="files-item-tpl">
    <li id="saved-file{id}">
        <input id="file-{id}" type="hidden" name="file_urls[]" value="{filepath}">
        <input class="form-control" id="file-{id}-name" type="text" name="file_names[]" value="{name}"
               style="width: 200px;" title="文件名称">
        <a id="file-{id}-preview" href="{preview_url}" target="_blank">下载</a>
        <a href="javascript:uploadOne('文件上传','#file-{id}','file');">替换</a>
        <a href="javascript:(function(){$('#saved-file{id}').remove();})();">移除</a>
    </li>
</script>
</head>
<body>
<div class="wrap js-check-wrap">
    <form action="" method="post" class="form-horizontal  margin-top-20 ">
        <div class="row">
            <div class="col-md-9">
                <table class="table table-bordered">
                    <input class="form-control" type="hidden" name="post[id]"  value="{$id}"  >
                    <tr>
                        <th>分类<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" name="post[category_id]"
                                   required value="{$category.name}" placeholder="" disabled/>
                                    
                        </td>
                    </tr>
                    
                    <tr>
                        <th>店名<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" name="post[name]"
                                   required value="{$shop.shop_name}" placeholder="" disabled/>
                        </td>
                    </tr>
                    <tr>
                        <th>管理员账号<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" name=""
                                   required value="{$tenant.user_login |default=''}" placeholder="" disabled/>
                        </td>
                    </tr>
                    <tr>
                        <th>管理员姓名<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" name=""
                                   required value="{$tenant.user_nickname |default=''}" placeholder="" disabled/>
                        </td>
                    </tr>
                    <tr>
                        <th>统一信用码</th>
                        <td>
                            <input class="form-control" type="text" name="post[account]" id="account" value="{$shop.license_id}" placeholder="" disabled>
                        </td>
                    </tr>
                    <tr>
                        <th>营业执照</th>
                        <td>
                            <img src="{$shop.certificate}">
                        </td>
                    </tr>
                    <tr>
                        <th>其他证照</th>
                        <td>
                            <if condition="!empty($shop['other_certificate'])">
                                <link rel="stylesheet" href="__STATIC__/css/viewer.min.css">
                                <script src="__STATIC__/js/viewer.min.js"></script>
                                <style type="text/css">
                                    .imglist img{
                                        width:120px;
                                        height: 120px;
                                        float: left;
                                    }
                                    .imglist ul{
                                        max-width: 300px;
                                    }
                                </style>
                                <ul id="other_certificate" class="imglist">
                                    <foreach name=":explode(',',$shop['other_certificate'])" item="vi">
                                        <li><img data-original="{:cmf_get_image_url($vi)}" src="{:cmf_get_image_url($vi)}" ></li>
                                    </foreach>
                                </ul>
                                <script>var viewer = new Viewer(document.getElementById('other_certificate'),{url:'data-original'});
                                </script>
                                <hr>
                            </if>
                        </td>
                    </tr>
                    <tr>
                        <th>法人身份证号</th>
                        <td>
                            <input class="form-control" type="text" name="post[account]" id="account" value="{$shop.idcard}" placeholder="" disabled>
                        </td>
                    </tr>
                    <tr>
                        <th>身份证照片</th>
                        <td>
                            
                            <img src="{$shop.id_pic1}" style="width: 350px;height: 200px;"/>
                            <img src="{$shop.id_pic2}" style="width: 350px;height: 200px;"/>
                        </td>
                    </tr>
                    <tr>
                        <th>地址</th>
                        <td>
                            <input class="form-control" type="text" name="post[account]" id="account" value="{$shop.shop_address}" placeholder="" disabled>
                        </td>
                    </tr>
                    <tr>
                        <th>坐标</th>
                        <td>
                            <input class="form-control" type="text" name="post[account]" id="account" value="{$shop.location}" placeholder="" disabled><div id="allmap"></div>
                        </td>
                    </tr>
                    <tr>
                        <th>经营范围</th>
                        <td>
                            <textarea class="form-control" type="text" name="post[scope]" id="scope" placeholder="" disabled>{$shop.scope}</textarea>
                        </td>
                    </tr>
                    <tr>
                        <th>营业时间</th>
                        <td>
                            <input class="form-control" type="text" name="post[account]" id="account" value="{$shop.onsale_time}" placeholder="" disabled>
                        </td>
                    </tr>
                    <tr>
                        <th>店铺相册</th>
                        <td>
                            <if condition="!empty($shop['shop_images'])">
                                <link rel="stylesheet" href="__STATIC__/css/viewer.min.css">
                                <script src="__STATIC__/js/viewer.min.js"></script>
                                <style type="text/css">
                                    .imglist img{
                                        width:120px;
                                        height: 120px;
                                        float: left;
                                    }
                                    .imglist ul{
                                        max-width: 300px;
                                    }
                                </style>
                                <ul id="shop_images" class="imglist">
                                    <foreach name=":explode(',',$shop['shop_images'])" item="vi">
                                        <li><img data-original="{:cmf_get_image_url($vi)}" src="{:cmf_get_image_url($vi)}" ></li>
                                    </foreach>
                                </ul>
                                <script>var viewer = new Viewer(document.getElementById('shop_images'),{url:'data-original'});
                                </script>
                                <hr>
                            </if>
                        </td>
                    </tr>
                    <tr>
                        <th>是否审核通过</th>
                        <td>
                            <if condition="$shop['checked'] eq 1">已审核通过

                                <else/>
                                未通过
                            </if>
                        </td>
                    </tr>
                    <tr>
                        <th>二维码</th>
                        <td>
                            <img src="{$shop.qrcode}"/>
                        </td>
                    </tr>
                </table>
                <hook name="portal_admin_article_edit_view_main"/>
               
            </div>
            
        </div>
    </form>
</div>
<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
<script type="text/javascript">
    //编辑器路径定义
    var editorURL = GV.WEB_ROOT;
</script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.config.js"></script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.all.min.js"></script>

<script type="text/javascript">
	
</script>

</body>
</html>
